<!--侧边栏(登录)-->
<!--幻灯+登录-->
<div class="PPT">
	<?php
	$data = M('IndexFocus')->limit(5)->order("listorder DESC")->select();
	?>
	<div id="jxy_div_indexPPT">
		<ul class="jxy_cls_indexPPT">
			{loop $data $r}
			<li><a target="_blank" title="{$r[title]}" href="{$r[url]}"><img src="{$r[image]}" height="300" width="980"></a></li>
			{/loop}
		</ul>
	</div>
	<ul class="PPT_opt">
		{loop $data $r}
		<li class="{if $n == 1}un{else}on{/if}"><img src="{$r[thumb]}" height="44" width="100"></li>
		{/loop}
	</ul>
	{php unset($data);}
			<script type="text/javascript" src="{THEME_STYLE_PATH}style/js/register.js"></script>
			<?php 
			$userinfo = is_login();
            ?>
			{if !$userinfo}
			<!--登录框(未)-->
			<form action="{U('Member/Index/login')}" method="post" id="login" name="login">
			<div class="Loginbox">
				<div class="Unlogin">
					<p class="a1">奖励发放累计：</p>
					{pc:document action="reward_total"}
					<p class="a2"><?php echo number_format($data);?>    <label>{type_change()}币</label></p>
					<p class="a3">价值：<label><?php echo number_format(exchange_money($data));?></label>人民币</p>
					{/pc}
					<p class="line"></p>
				</div>
				<div class="Loginipt">
					<div class="Lipt_name">用户名：</div>
					<div class="Lipt_ipt" style="position:relative;"><input type="text" id="loginUser" name="username" class="lipt1_on" /><span class="tip">请输入昵称/邮箱/ID</span></div><!--鼠标点击 VALUE清空 样式“lipt1_on”-->	
					<div class="clear"></div>
				</div>
				<div class="Loginipt">
					<div class="Lipt_name">密&nbsp;&nbsp;&nbsp;码：</div>
					<div class="Lipt_ipt"><input type="password" id="loginPwd" name="password" class="lipt1_on" /></div>
					<div class="clear"></div>
				</div>
				
				<?php if ($setting['enablcodecheck']): ?>
				<div class="Loginipt2">
					<div class="Lipt_name">验&nbsp;证&nbsp;码：</div>
					<div class="Lipt_ipt"><input size="4" maxlength="4" id="jxy_codeIpt" name="verify" class="lipt1_on2" type="text" /><span style="position:absolute;top:190px;left:160px;"><img src="{U('Api/Verify/create')}" id="vCode_pic" style="cursor:pointer;vertical-align: -10px;" title="点击刷新" /></span><span class="regtrue" id="verify_done" style="display:none;"></span><span class="regwrong" id="verify_wrong" style="display:none;"></span></div>
					<div class="clear"></div>
				</div>
				<?php endif; ?>
				
				<div class="Loginbtn">
					<a href="javascript:void(0);" class="lbtn" onclick="document.getElementById('login').submit();">登&nbsp;&nbsp;&nbsp;&nbsp;录</a><a href="{U('Member/Index/forget')}" target="_blank">忘记密码？</a><span><a href="{U('Member/Index/register')}" class="sreglink" target="_blank">免费注册!</a></span>
				</div>
				<!--错误提示，显示1秒后隐藏-->
				<div class="loginwrg" style="display:none;">用户名或密码错误，请重新输入！</div>
				<!--错误提示，显示1秒后隐藏-->
			</div>
			</form>
			<!--登录框(未)-->
			{else}
			<!--登录框(已)-->
			<div class="Loginbox">
				<div class="Perbox">
					<div class="Per_head"><a href="{U('Member/Profile/index')}" target="_blank"><img src="{THEME_STYLE_PATH}style/avatar/default/<?php if( getUserInfo($this->userid,'photo',TRUE)){echo getUserInfo($this->userid,'photo',TRUE);}else{echo 1;}?>.jpg"></a></div>
					<div class="Per_info">
						<p class="a1"><strong>欢迎回来！</strong><label><a href="{U('Member/Index/logout')}" class="da3">[退出]</a></label></p>
						<p class="a2"><span class="ofe"><strong><?php echo $userinfo['nickname'];?></strong></span><br><label class="da3">ID:{$userinfo[userid]}</label></p>
						<p class="a3"></p><div id="rightsign" style="z-index:9999;display:none;position:absolute;font:bold 20px '微软雅黑','黑体';color:#FF0000;top:50px;left:108px"></div>
						{if !is_sign($userinfo['userid'])}
						<a href="{U('Member/Sign/index')}" target="_blank" class="mrqd">签到</a>&nbsp;
						{else}
						<a href="javascript:void(0);" class="mrqd_un">已签到</a>
						{/if}
						&nbsp;<a href="{U('Member/Profile/index')}" class="Percbtn">进入会员中心</a><p></p>
					</div>
					<div class="clear"></div>
					<div class="Unlogin">
						<p class="line"></p>
					</div>
					<div class="Per_info2">
						<p class="a1">当前{type_change()}币：<span class="ofe"><strong><?php echo doFormatMoney($userinfo['u_coin'])?></strong></span><img src="{THEME_STYLE_PATH}style/images/ub.gif" class="ub14">&nbsp;<a href="{U('Member/Account/cash')}" target="_blank">[提现]</a>&nbsp;&nbsp;
						<p class="a1">当前{type_change()}豆：<span class="ofe"><strong><?php echo doFormatMoney($userinfo['u_bean'])?></strong></span>&nbsp;<a href="{U('Member/Score/u_bean')}" target="_blank">[查看明细]</a></p>
						<p class="a2">今日预计上线广告：<span class="ofe"><strong>13</strong></span>个&nbsp;<a href="{U('document/Index/lists',array('catid'=>2))}" target="_blank">[立即体验]</a></p>
					</div>
				</div>
				<div style="position:absolute; bottom:14px;display:none;"><a href="#" target="_blank" style="color:#0000FF;">种鲜花，{type_change()}币、话费轻松拿</a></div>
							</div>
			<!--登录框(已)-->
			{/if}
					</div>
		<!--幻灯+登录-->
<script language="javascript">
document.onkeydown = function(e){    
    var ev = document.all ? window.event : e;  
    if(ev.keyCode==13) {
    	document.login.submit();
    // 如（ev.ctrlKey && ev.keyCode==13）为ctrl+Center 触发  
        //要处理的事件  
    }  
  }  
</script>